﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;

namespace BasicInformation.Infrastructure
{
    public interface IBaseRepository<T> where T :class
    {
        Task<int> Create(T model);
        Task<int> Update(T model);
        Task<int> UpdateRange(List<T> info);
        Task<int> Delete(int id);
        Task<int> DeleteInfo(Expression<Func<T, bool>> info);
        Task<int> DeleteList(IQueryable<T> info);
        Task<T> GetInfo(Expression<Func<T, bool>> info);
        Task<T> Get(int id);
        Task<List<T>> GetList();
        Task<List<T>> GetListInfo(Expression<Func<T, bool>> info);
    }
}
